import React, { useEffect, useState } from 'react'
import style from './style.module.scss'
import { Link } from 'react-router-dom'
import { FacebookFilled, TwitterOutlined, WeiboOutlined } from '@ant-design/icons'
import BaseLayout from '../../_Layout/BaseLayout'
import { UserService } from '../../../transfer/service/UserService'

export default function NormalFooter() {
    const [data, setData] = useState<any>({})

    useEffect(() => {
        new UserService().getProfile(JSON.parse(localStorage.getItem('account') as any).id).then(res => {
            setData(res.data.data.profile)
        })
    }, [])
    return (
        <BaseLayout>
            <div className={style.container}>
                <div className={style.title}>
                    <span>LineView</span>
                    <div className={style.icon__list}>
                        <WeiboOutlined className={style.icon} />
                        <TwitterOutlined className={style.icon} />
                        <FacebookFilled className={style.icon} />
                    </div>
                </div>
                <div className={style.line} />
                <div className={style.list}>
                    <span>做点很棒的事，{data.nickName}。</span>
                    <div className={style.list__content}>
                        <Link to={'#'}>许可</Link>
                        <Link to={'#'}>隐私政策</Link>
                        <Link to={'#'}>条款</Link>
                    </div>
                </div>
            </div>
        </BaseLayout>
    )
}
